<template>
  <h1>EL-布局组件</h1>
  <el-row :gutter="10">
    <el-col :span="6">测试数据</el-col>
    <el-col :span="6">测试数据</el-col>
    <el-col :span="6">测试数据</el-col>
    <el-col :span="6">测试数据</el-col>
  </el-row>

  <hr>

  <el-row :gutter="10">
    <el-col :span="12">
      <img src="guodong.jpg" width="200px" alt="你好">
    </el-col>
    <el-col :span="12">
      <img src="guodong.jpg" width="200px" alt="你好">
    </el-col>
  </el-row>

  <h3>3张图 宽度要求是1:2:3</h3>

  <el-row :gutter="10">
    <el-col :span="4"><img src="guodong.jpg" alt=""></el-col>
    <el-col :span="8"><img src="guodong.jpg" alt=""></el-col>
    <el-col :span="12"><img src="guodong.jpg" alt=""></el-col>
  </el-row>

  <h3>列偏移</h3>
  <el-row :gutter="10">
    <!--    :offset=""列偏移，默认值为0，默认靠左，写几就是向右移动几列-->
    <el-col :span="20" :offset="2"><img src="guodong.jpg" style="width: 100%" alt=""></el-col>
  </el-row>

  <!--  插图：12列居中-->
  <el-row :gutter="10">
    <el-col :span="12" :offset="6"><img src="guodong.jpg" style="width: 100%" alt=""></el-col>
  </el-row>

  <el-row :gutter="10">
    <el-col :span="3" v-for="n in 8">{{ n }}</el-col>
  </el-row>

  <!--  布局嵌套-->
  <el-row>
    <el-col :span="12" style="border: red 3px solid"></el-col>
    <el-col :span="12" style="border: green 3px solid">
      <el-row>
       <el-col :span="8" style="border: blue 3px solid">卡片1</el-col>
       <el-col :span="8" style="border: blue 3px solid"><img src="guodong.jpg" width="100%" alt=""></el-col>
       <el-col :span="8" style="border: blue 3px solid">卡片3</el-col>
      </el-row>
    </el-col>
  </el-row>
</template>

<script setup>

</script>

<style scoped>

</style>